#!/usr/bin/env python
# -*- coding:utf-8 -*-
# Author:Shu Yang Wang
# Date: 2017/9/5

'''
md5加密验证
'''

def encrypt(pwd):
    '''
    md5加密
    :param pwd:明文密码 
    :return: 
    '''
    import hashlib
    
    obj = hashlib.md5()
    obj.update(pwd.encode('utf-8'))
    data = obj.hexdigest()
    return data